Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

scanner: Use std::convert::Infallible in __phantom_lifetime variants #662

Merged
merged 1 commit into from
Sep 25, 2023

Conversation

ids1024
Copy link
Member

@ids1024 ids1024 commented Sep 25, 2023

I thought there was an empty type in the standard library, but somehow couldn't find it when I implemented this.

This makes it a bit more explicit that the variant is never constructed, and should help a bit with optimization. It does not impact public API.

@codecov
Copy link

codecov bot commented Sep 25, 2023

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (bb133c1) 73.04% compared to head (c5789e9) 73.04%.

❗ Current head c5789e9 differs from pull request most recent head a4e3793. Consider uploading reports for the commit a4e3793 to get more accurate results

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #662   +/-   ##
=======================================
  Coverage   73.04%   73.04%           
=======================================
  Files          47       47           
  Lines        7779     7779           
=======================================
  Hits         5682     5682           
  Misses       2097     2097           
Flag Coverage Δ
main 58.31% <100.00%> (-0.03%) ⬇️
test-- 78.08% <100.00%> (+<0.01%) ⬆️
test--server_system 61.35% <100.00%> (ø)
test-client_system- 69.11% <100.00%> (+0.01%) ⬆️
test-client_system-server_system 51.42% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
wayland-scanner/src/common.rs 95.84% <100.00%> (ø)

... and 2 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@elinorbgr
Copy link
Member

Looks good, can you add a changelog entry with that please?

I thought there was an empty type in the standard library, but somehow
couldn't find it when I implemented this.

This makes it a bit more explicit that the variant is never constructed,
and should help a bit with optimization. It does not impact public API.
@elinorbgr
Copy link
Member

Thanks!

@elinorbgr elinorbgr merged commit 599480b into Smithay:master Sep 25, 2023
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants